#!/usr/bin/env bash
#
# Summary: List installed packages
# Usage: basher list

set -e

if [ "$#" -gt 0 ]; then
  basher-help list
  exit 1
fi

shopt -s nullglob

for package_path in ${BASHER_PACKAGES_PATH}/*/*
do
  username="$(dirname "$package_path")"
  username="${username##*/}"
  package="${package_path##*/}"
  echo "$username/$package"
done
